#include "regex_base.h"


alt regex_base::operator|(const regex_base& x) const
{
     alt a;
     a.options.push_back(this->copy());
     a.options.push_back(x.copy());
     return a;
}

mt0 regex_base::operator*() const
{
     return mt0(*this);
}

seq regex_base::operator>>(const regex_base& r) const
{
    seq s;
    s.word.push_back(this->copy());
    s.word.push_back(r.copy());
    return s;
}

seq regex_base::operator+() const
{
    seq s;
    s.word.push_back(this->copy());
    s.word.push_back(new mt0(*this->copy()));
    return s;
}
